<?php
/**
 * Created by PhpStorm.
 * User: shuixian
 * Date: 2019/11/20
 * Time: 18:29
 */


$cate = <<<CATE
{
	"title": "分类导航",
	"type": "restaurantCateList",
	"icon": "icondaohang3",
	"isDelete": true,
	"addNumber": 9999,
	"attr": [{
		"title": "图片列表",
		"type": "ImageLink",
		"name": "columnList",
		"isDraggable": true,
		"isDelete": true,
		"data": [{
			"title": "按钮文字",
			"type": "Input",
			"name": "title"
		}, {
			"title": "图片",
			"type": "UploadImage",
			"name": "img",
			"desc": "100*100"
		}, {
			"title": "链接类型",
			"type": "Select",
			"name": "linkType",
			"data": [{
				"label": "系统内部页面",
				"value": 4
			}, {
				"label": "其他小程序",
				"value": 2
			}, {
				"label": "跳转网页",
				"value": 3
			}, {
				"label": "拨打电话",
				"value": 1
			}]
		}, {
			"title": "链接地址",
			"type": "Tag",
			"name": "link"
		}]
	}, {
		"title": "添加模板",
		"type": "Add",
		"name": "addMouduleName",
		"addNumber": 4,
		"data": [{
			"link": [{
				"title": ""
			}],
			"linkType": 4,
			"img": [{
				"url": "http://lbqny.migugu.com/admin/diy/default.png"
			}]
		}]
	}],
	"data": {
		"addMouduleName": "columnList",
		"columnList": [{
			"title": "按钮文字",
			"link": [{
				"title": ""
			}],
			"linkType": 4,
			"img": [{
				"url": "http://lbqny.migugu.com/admin/diy/default.png"
			}]
		}, {
			"title": "按钮文字",
			"link": [{
				"title": ""
			}],
			"linkType": 4,
			"img": [{
				"url": "http://lbqny.migugu.com/admin/diy/default.png"
			}]
		}]
	}
}
CATE;



$goods = <<<GOODS
 {
 	"title": "推荐列表",
 	"type": "restaurantGoodsList",
 	"icon": "iconMyGoods",
 	"isDelete": true,
 	"addNumber": 1,
 	"attr": [{
 		"title": "模板名称",
 		"type": "Input",
 		"name": "title",
 		"maxLength": 10
 	}, {
 		"title": "更多名称",
 		"type": "Input",
 		"name": "more",
 		"maxLength": 10
 	}, {
 		"title": "显示更多",
 		"type": "Switch",
 		"name": "isShowMoreBtn"
 	}],
 	"data": {
 		"title": "推荐",
 		"more": "查看更多",
 		"isShowMoreBtn": true
 	},
 	"dataList": []
 }

GOODS;

$new = <<<New
{
	"title": "新人专区",
	"type": "restaurantNewList",
	"icon": "iconGoodsList",
	"isDelete": true,
	"addNumber": 1,
	"attr": [{
		"title": "模板名称",
		"type": "Input",
		"name": "title",
		"maxLength": 10
	}, {
		"title": "更多名称",
		"type": "Input",
		"name": "more",
		"maxLength": 10
	}, {
		"title": "显示更多",
		"type": "Switch",
		"name": "isShowMoreBtn"
	}],
	"data": {
		"title": "新人专区",
		"more": "更多低价菜品",
		"isShowMoreBtn": true
	},
	"dataList": []
}
New;

//$search = <<<SEARCH
//{"title":"搜索栏","type":"search","iconPath":"iconsousuo","isDelete":true,"addNumber":1,"attr":[{"title":"是否显示分类","type":"Switch","name":"isShowCateAll"}],"data":{"placeholder":"请输入搜索内容","isShowCateAll":true}}
//
//SEARCH;

//模块组件 后台DIY页面的左侧
return [

    [
        "title" => "业务组件",

        'type' => 'restaurantCompoent',

        'data' =>[

            json_decode($cate, true),

            // json_decode($new, true),

            // json_decode($goods, true),

        ]
    ],
];